package com.bigshark.api.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.bigshark.api.mapper.BannerMapper;
import com.bigshark.api.model.Banner;
import com.bigshark.api.service.BannerService;
import org.springframework.stereotype.Service;

import java.util.List;

@Service("BannerService")
public class BannerServiceImpl extends ServiceImpl<BannerMapper,Banner> implements BannerService {

    public List<Banner> queryBannerList(Integer num){
        return baseMapper.selectList(new QueryWrapper<Banner>().last("limit "+ num));
    }

}
